package com.ihrm.common.entity;

public enum ResultCode {
    SUCCESS(true,10000,"操作成功!"),
    //-----系统错误返回码
    FAIL(false,10001,"操作失败！"),
    UNAUTHENTICATED(false,10002,"你还未登陆"),
    UNAUTHORISE(false,10003,"权限不足"),
    SERVER_ERROR(false,99999,"抱歉，系统繁忙，请稍后重试！"),

    //-----用户操作返回码  2xxxx----
    MOBILEORPASSWORDERROR(false,20001,"用户名或手机号不对");

    //-----企业操作返回码  3xxxx----
    //-----权限操作返回码
    //-----其他操作返回码

    private boolean success;
    private int code;
    private String message;

    ResultCode(boolean success,int code,String message){
        this.success = success;
        this.code = code;
        this.message = message;
    }

    public boolean success(){
        return success;
    }

    public int code(){
        return code;
    }

    public String message(){
        return message;
    }
}
